package cn.com.roy.thread.t4_1_14.awaituninterruptiblytest1;



public class Run {
    public static void main(String[] args) {
        try {
            final Myservice myservice = new Myservice();
            Runnable runnable = new Runnable() {
                public void run() {
                    myservice.testMethod();
                }
            };

            Thread t1 = new Thread(runnable);
            t1.setName("A");
            t1.start();
            Thread.sleep(3000);
            t1.interrupt();


        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
